home *** CD-ROM | disk | FTP | other *** search
/ Shareware Grab Bag / Shareware Grab Bag.iso / 007 / msc3eof.pqt / msc3eof.pat
Encoding:
Text File  |  1986-04-26  |  1.3 KB  |  31 lines

  1. u 1cc l d
  2. a 1cf
  3. ; Bug Fix for MSC 3.0 eof()     Memory Model(s): S,M
  4. ;
  5. ; The following fix corrects a bug in the function eof() from the
  6. ;   Microsoft C 3.0 Compiler Library.
  7. ; The original code calls tell() to determine where the current file
  8. ;   position is, and compares it to the result of filelength(). Un-
  9. ;   fortunately, in the Small and Medium Memory Model libraries, the
  10. ;   long int result from tell() is improperly treated as a signed
  11. ;   int which is then CONVERTED to a long int. Result: eof() does
  12. ;   not recognize end of file for files between (for example) 32768
  13. ;   and 65535 bytes long.
  14. ; To apply this fix, extract eof.obj from slibc.lib (or mlibc) with:
  15. ;       LIB slibc *eof;
  16. ; Then patch the object module and create a new library
  17. ;       DEBUG eof.obj <msc3eof.pat
  18. ; Next, create a new object library to contain the fixed module
  19. ;       LIB sfixlibc +eof;
  20. ; Finally, whereever LINK with slibc, use sfixlibc+slibc instead.
  21. ; For the Medium Model library mlibc, change the addresses above to:
  22. ;     1CC->1D3,   1CF->1D6.
  23. ;
  24. ; Bug Reported to Microsoft 03/14/86.
  25. ;
  26. ;          Frank McKenney, McKenney Associates
  27. ;          Richmond, Virginia   (804) 320-4887
  28. nop
  29.  
  30. u 1cc l d
  31. wq